<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Casts\Attribute;

class Widget extends Model
{
    /**
     * 与模型关联的数据表.
     *
     * @var string
     */
    protected $table = 'widget';

    /**
     * 指示模型是否主动维护时间戳。
     *
     * @var bool
     */
    public $timestamps = false;


    public  function getFirstAttribute($value)
    {
        return json_decode($value, true);
    }

    public  function getPicAttribute($value)
    {
        return json_decode($value, true);
    }

    public  function getSecondAttribute($value)
    {
        return json_decode($value, true);
    }
}
